Page({
  getUserInfo(e){
    console.log(e);

  },
  getInfo(){
    wx.getUserProfile({
      desc: 'desc',
      success(res){
        console.log(res);
        wx.login({
          // timeout: 0,
          success(res){
            console.log(res);
            wx.request({
              url:"http://localhost:3000/checkUser/info",
              method:"POST",
              header: {"content-type":'application/x-www-form-urlencoded'},
              data:{
                code:res.code
              },
              success(result){
                console.log(result);
              }
            })
          }
        })

      }
    })
  }
})